<script>
    jxt.text.newJson = function(dataJson, _t) {
        if (_t !== '') {
            if (!_t) _t = jxt.text.dataJson.init.text;
        }
        if (!dataJson) dataJson = jxt.text.dataJson;
        var _self = jxt.tag.newJson(dataJson);

        _self.content = _t;
        return _self;
    };


    jxt.text.editend = function(eleid) {
        var jxtid = eleid;
        if (!jxtid) {
            alert("iderr:" + jxtid);
            return;
        }
        var node = jxt.getnode(jxtid);
        if (!node) {
            alert("err:" + jxtid);
            return;
        }
        var ele = $("#" + jxtid);

        var txt = $.trim($(ele).val());
        if (node.content == txt) return;

        node.content = txt;

        jxt.msg.radio(eleid, "nodechange");

    };
</script>